package com.cky.forum.services;

import com.cky.forum.model.Article;
import org.apache.ibatis.annotations.Param;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

public interface IArticleService {
    @Transactional//当前方法中的执行过程会被事务管理起来
    void create (Article article);
    List<Article> selectAll();

    List<Article> selectAllByBoardId(Long boardId);

    Article selectDetailById(Long id);
    Article selectById(Long id);
    public void modify(Long id,String title,String content);
    void thumbsUpById(Long id);
    @Transactional
    void deleteById(Long id);
    void addOneReplyCountById(Long id);
    List<Article> selectByUserId(Long userId);
}
